package com.example.shop_2302.pay

import android.os.Bundle
import androidx.activity.enableEdgeToEdge
import androidx.appcompat.app.AppCompatActivity
import androidx.core.view.ViewCompat
import androidx.core.view.WindowInsetsCompat
import com.alibaba.android.arouter.facade.annotation.Autowired
import com.alibaba.android.arouter.facade.annotation.Route
import com.alibaba.android.arouter.launcher.ARouter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.example.base.mvvm.BaseViewActivity
import com.example.shop_2302.R
import com.example.shop_2302.databinding.ActivityPayResultBinding

@Route(path = "/app/PayResultActivity")
class PayResultActivity : BaseViewActivity<ActivityPayResultBinding>() {
    @Autowired
    @JvmField
    var result = ""
    override fun initView() {
        ARouter.getInstance().inject(this)
        binding.tvResult.text = result

        binding.tvIndex.setOnClickListener {
            ARouter.getInstance().build("/app/ShopActivity").navigation()
        }
        //查看订单在我的界面中
        binding.tvOrder.setOnClickListener {
            ARouter.getInstance().build("/app/ShopActivity").withInt("position",3).navigation()
        }

    }

    override fun initData() {

    }

    override fun getLayout(): Int  = R.layout.activity_pay_result

}